19 Lecture

CS201

Midterm & Final Term Short Notes

Sequential Access Files (Continued)

Sequential Access Files are data files where data is stored in a sequential manner, and data can only be accessed in a particular order. These files are typically used for batch processing where data needs to be read or written in a sequential m


Important Mcq's
Midterm & Finalterm Prepration
Past papers included

Download PDF
  1. Which of the following is true about Sequential Access Files? a) Data can be accessed randomly b) Data can only be accessed in a particular order c) They are used for real-time processing d) They are inefficient in handling large amounts of data

Answer: b) Data can only be accessed in a particular order

  1. Which of the following is an advantage of Sequential Access Files? a) Random access to data b) Require high overhead c) Can handle large amounts of data efficiently d) Suitable for real-time processing

Answer: c) Can handle large amounts of data efficiently

  1. Which of the following is a disadvantage of Sequential Access Files? a) Random access to data b) Require less overhead c) Can handle small amounts of data efficiently d) Not suitable for real-time processing

Answer: a) Random access to data

  1. Sequential Access Files are commonly used in which of the following applications? a) Gaming b) Social media c) Accounting d) Email

Answer: c) Accounting

  1. Which of the following is an example of a Sequential Access File? a) A database b) A text file c) A spreadsheet d) A binary file

Answer: b) A text file

  1. Which of the following is true about writing data to a Sequential Access File? a) Data can be written randomly b) Data can only be written in a particular order c) It is suitable for real-time processing d) It requires high overhead

Answer: b) Data can only be written in a particular order

  1. Which of the following is an example of a situation where Sequential Access Files are suitable? a) Searching for a specific record in a database b) Modifying a record in a database c) Printing a report from a database d) Real-time data processing

Answer: c) Printing a report from a database

  1. Which of the following is a disadvantage of using Sequential Access Files for large data sets? a) They are inefficient in handling large amounts of data b) They require high overhead c) They are not suitable for real-time processing d) They allow random access to data

Answer: a) They are inefficient in handling large amounts of data

  1. Which of the following is an advantage of using Sequential Access Files for batch processing? a) They allow random access to data b) They are suitable for real-time processing c) They require less overhead d) They can handle small data sets efficiently

Answer: c) They require less overhead

  1. Which of the following is true about reading data from a Sequential Access File? a) Data can be read randomly b) Data can only be read in a particular order c) It is suitable for real-time processing d) It requires high overhead

Answer: b) Data can only be read in a particular order



Subjective Short Notes
Midterm & Finalterm Prepration
Past papers included

Download PDF
  1. What is a Sequential Access File? Answer: A Sequential Access File is a data file where data is stored in a sequential manner and can only be accessed in a particular order.

  2. How does a Sequential Access File differ from a Random Access File? Answer: A Sequential Access File can only be accessed in a particular order, while a Random Access File allows for random access to data.

  3. What are the advantages of using Sequential Access Files? Answer: Advantages of using Sequential Access Files include efficient handling of large amounts of data, simplicity in implementation, and low overhead.

  4. What are the disadvantages of using Sequential Access Files? Answer: Disadvantages of using Sequential Access Files include the inability to access data randomly, inefficiency in handling small data sets, and unsuitability for real-time processing.

  5. What type of applications are Sequential Access Files commonly used in? Answer: Sequential Access Files are commonly used in batch processing applications such as accounting, payroll, and inventory management systems.

  6. How is data written to a Sequential Access File? Answer: Data is written to a Sequential Access File in a particular order, one record at a time.

  7. How is data read from a Sequential Access File? Answer: Data is read from a Sequential Access File in a particular order, one record at a time.

  8. Can a Sequential Access File be modified after it has been created? Answer: Yes, a Sequential Access File can be modified by adding or deleting records, but the order of the records cannot be changed.

  9. What are some common file formats used for Sequential Access Files? Answer: Common file formats used for Sequential Access Files include text files, CSV files, and log files.

  10. What are some alternative file storage methods to Sequential Access Files? Answer: Alternative file storage methods include Random Access Files, Indexed Files, and Relational Databases.

Sequential Access Files are an important data storage technique used in various applications for batch processing. In this type of file, data is stored in a sequential order, and access to the data can only be done in the same order. This makes the process of reading and writing data much simpler, requiring less overhead, and can handle large amounts of data efficiently. One of the primary benefits of using Sequential Access Files is its simplicity in implementation. Because the data is stored in a specific order, the software developers do not have to create any complicated data structures or algorithms to read and write data. This leads to lower overhead and faster processing times. However, there are some disadvantages of using Sequential Access Files. One major drawback is the inability to access data randomly. If a program needs to access a particular piece of data, it must read through all the records until it reaches the desired record. This process can be time-consuming and inefficient for large datasets. Despite these disadvantages, Sequential Access Files are still commonly used in many batch processing applications, such as accounting systems, inventory management systems, and payroll processing systems. These systems typically involve the creation of large data files that contain transactional data. These files can then be processed in batches at a later time, often at the end of the day or week. To create a Sequential Access File, the programmer first defines the structure of the data record. This structure includes the fields that will be included in each record and their corresponding data types. Once the structure is defined, data can be written to the file, one record at a time. To read data from the file, the program reads each record in sequence until it reaches the end of the file. In conclusion, Sequential Access Files are an important data storage technique used in various batch processing applications. While they may have some limitations, they remain a useful tool for handling large datasets efficiently and with less overhead. Programmers must carefully consider the type of data and the specific needs of the application before choosing this file storage method.